Skip to content

Conversation

@jguz-pubnub
Copy link
Contributor

@jguz-pubnub jguz-pubnub commented Aug 7, 2025

fix(presence): fix APM libraries crash (when present) by centralizing HTTPSession cleanup

APM libraries crash fix: Removed deinit methods that were calling session.invalidateAndCancel() from PresenceEffectFactory and SubscribeEffectFactory to prevent race conditions with Application Performance Monitoring libraries. Session cleanup now happens exclusively in HTTPSession.deinit, which ensures request cancellation before invalidation. This prevents crashes from occurring inside APM libraries when they intercept network operations during session invalidation.

Copy link
Contributor

@parfeon parfeon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@jguz-pubnub
Copy link
Contributor Author

@pubnub-release-bot release as 9.3.3

@jguz-pubnub jguz-pubnub changed the title Fix APM library crash (when present) by centralizing HTTPSession cleanup Fix APM libraries crash (when present) by centralizing HTTPSession cleanup Aug 7, 2025
@jguz-pubnub jguz-pubnub merged commit 2090b6d into master Aug 7, 2025
12 checks passed
@jguz-pubnub jguz-pubnub deleted the fix/apm-crash branch August 7, 2025 12:41
@pubnub-release-bot
Copy link

🚀 Release successfully completed 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants